package com.site.blog.my.core.entity;

import com.fasterxml.jackson.annotation.JsonFormat;

import java.util.Date;

public class BlogComment {
	private Long commentId;

	private Long blogId;

	private String commentator;

	private String email;

	private String websiteUrl;

	private String commentBody;
	//时间格式化
	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	private Date commentCreateTime;

	private String commentatorIp;

	private String replyBody;

	@JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
	private Date replyCreateTime;

	private Byte commentStatus;

	private Byte isDeleted;

	public Long getCommentId() {
		return commentId;
	}

	public void setCommentId(Long commentId) {
		this.commentId = commentId;
	}

	public Long getBlogId() {
		return blogId;
	}

	public void setBlogId(Long blogId) {
		this.blogId = blogId;
	}

	public String getCommentator() {
		return commentator;
	}

	public void setCommentator(String commentator) {
		this.commentator = commentator == null ? null : commentator.trim();
	}

	public String getEmail() {
		return email;
	}

	public void setEmail(String email) {
		this.email = email == null ? null : email.trim();
	}

	public String getWebsiteUrl() {
		return websiteUrl;
	}

	public void setWebsiteUrl(String websiteUrl) {
		this.websiteUrl = websiteUrl == null ? null : websiteUrl.trim();
	}

	public String getCommentBody() {
		return commentBody;
	}

	public void setCommentBody(String commentBody) {
		this.commentBody = commentBody == null ? null : commentBody.trim();
	}

	public Date getCommentCreateTime() {
		return commentCreateTime;
	}

	public void setCommentCreateTime(Date commentCreateTime) {
		this.commentCreateTime = commentCreateTime;
	}

	public String getCommentatorIp() {
		return commentatorIp;
	}

	public void setCommentatorIp(String commentatorIp) {
		this.commentatorIp = commentatorIp == null ? null : commentatorIp.trim();
	}

	public String getReplyBody() {
		return replyBody;
	}

	public void setReplyBody(String replyBody) {
		this.replyBody = replyBody == null ? null : replyBody.trim();
	}

	public Date getReplyCreateTime() {
		return replyCreateTime;
	}

	public void setReplyCreateTime(Date replyCreateTime) {
		this.replyCreateTime = replyCreateTime;
	}

	public Byte getCommentStatus() {
		return commentStatus;
	}

	public void setCommentStatus(Byte commentStatus) {
		this.commentStatus = commentStatus;
	}

	public Byte getIsDeleted() {
		return isDeleted;
	}

	public void setIsDeleted(Byte isDeleted) {
		this.isDeleted = isDeleted;
	}

	@Override
	public String toString() {
		StringBuilder sb = new StringBuilder();
		sb.append(getClass().getSimpleName());
		sb.append(" [");
		sb.append("Hash = ").append(hashCode());
		sb.append(", commentId=").append(commentId);
		sb.append(", blogId=").append(blogId);
		sb.append(", commentator=").append(commentator);
		sb.append(", email=").append(email);
		sb.append(", websiteUrl=").append(websiteUrl);
		sb.append(", commentBody=").append(commentBody);
		sb.append(", commentCreateTime=").append(commentCreateTime);
		sb.append(", commentatorIp=").append(commentatorIp);
		sb.append(", replyBody=").append(replyBody);
		sb.append(", replyCreateTime=").append(replyCreateTime);
		sb.append(", commentStatus=").append(commentStatus);
		sb.append(", isDeleted=").append(isDeleted);
		sb.append("]");
		return sb.toString();
	}
}